package com.itheima.homework;

import javax.security.sasl.SaslClient;
import java.util.Scanner;

public class Demo2 {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        System.out.println("请输入字符串");
        String s = sc.nextLine();

        char[] chars = s.toCharArray();
        for (int i = 0; i < chars.length; i++) {
            System.out.print(chars[i] + " ");
        }
        System.out.println();

        for(int i = 0;i < s.length();i++){
            char c = s.charAt(i);
            System.out.print(c + " ");
        }

    }
}
